<?php

namespace App\Models;


class VoiceSearchMusic
{
    static function openHome()
    {
        return [
            'status' => 0,
            'message' => '',
            'datas' => [
                [
                    'model' => 'music',
                    'targetActions' => [
                        [
                            "active_type" => "scheme",
                            'url' => 'musictv://?action=0&pull_from=12121&mb=true'
                        ]
                    ]
                ]
            ]
        ];
    }

    static function openTops()
    {
        return [
            'status' => 0,
            'message' => '',
            'datas' => [
                [
                    'model' => 'music',
                    'targetActions' => [
                        [
                            "active_type" => "scheme",
                            'url' => 'musictv://?action=1&pull_from=12121&mb=true'
                        ]
                    ]
                ]
            ]
        ];
    }

    static function openNewes()
    {
        return [
            'status' => 0,
            'message' => '',
            'datas' => [
                [
                    'model' => 'music',
                    'targetActions' => [
                        [
                            "active_type" => "scheme",
                            'url' => 'mmusictv://?action=2&pull_from=12121&mb=true'
                        ]
                    ]
                ]
            ]
        ];
    }

    static function openHotSingers()
    {
        return [
            'status' => 0,
            'message' => '',
            'datas' => [
                [
                    'model' => 'music',
                    'targetActions' => [
                        [
                            "active_type" => "scheme",
                            'url' => 'musictv://?action=4&pull_from=12121&mb=true'
                        ]
                    ]
                ]
            ]
        ];
    }

    static function openRadios()
    {
        return [
            'status' => 0,
            'message' => '',
            'datas' => [
                [
                    'model' => 'music',
                    'targetActions' => [
                        [
                            "active_type" => "scheme",
                            'url' => 'musictv://?action=5&pull_from=12121&mb=true'
                        ]
                    ]
                ]
            ]
        ];
    }

    static function openMyHome()
    {
        return [
            'status' => 0,
            'message' => '',
            'datas' => [
                [
                    'model' => 'music',
                    'targetActions' => [
                        [
                            "active_type" => "scheme",
                            'url' => 'musictv://?action=7&pull_from=12121&mb=true'
                        ]
                    ]
                ]
            ]
        ];
    }

    static function openMyHistroys()
    {
        return [
            'status' => 0,
            'message' => '',
            'datas' => [
                [
                    'model' => 'music',
                    'targetActions' => [
                        [
                            "active_type" => "scheme",
                            'url' => 'musictv://?action=9&pull_from=12121&mb=true'
                        ]
                    ]
                ]
            ]
        ];
    }

    static function openAllPlaylist()
    {
        return [
            'status' => 0,
            'message' => '',
            'datas' => [
                [
                    'model' => 'music',
                    'targetActions' => [
                        [
                            "active_type" => "scheme",
                            'url' => 'musictv://?action=13&pull_from=12121&mb=true'
                        ]
                    ]
                ]
            ]
        ];
    }

    static function searchByKeyword($text)
    {
        $text = str_replace(['我要听', '我想听' ,'的歌'], '', $text);
        return [
            'status' => 0,
            'message' => '',
            'datas' => [
                [
                    'model' => 'music',
                    'targetActions' => [
                        [
                            "active_type" => "scheme",
                            'url' => 'musictv://?action=8&pull_from=12121&search_key=' . urlencode($text) . '&m1=false&mb=true'
                        ]
                    ]
                ]
            ]
        ];
    }
}
